/*
 * Copyright (c) 2019-2020, https://api.iot.10086.cn/(https://gitee.com/cmcc-iot-api/iot-card-open-application/).
 */
package cn.iot.card.open.sim.dto.general;

import cn.iot.card.open.constants.Constants;

/**
 * 物联卡状态变更DTO
 *
 * @author 何光鑫
 * @date 20200315 12:55:02
 * @modify 20200315 何光鑫 v1.1.2 创建
 * @since v1.1.2
 */
public class ChangeSimStatusDTO {
    /**
     * 卡号类型（msisdn、iccid、imsi）
     */
    private String cardType;

    /**
     * 卡号
     */
    private String cardNum;

    /**
     * 变更类型
     *
     * 0:申请停机(已激活转已停机)
     * 1:申请复机(已停机转已激活)
     * 2:库存转已激活
     * 3:可测试转库存
     * 4:可测试转待激活
     * 5:可测试转已激活
     * 6:待激活转已激活
     */
    private String operType;

    public String getCardType() {
        return cardType;
    }

    public void setCardType(String cardType) {
        this.cardType = cardType;
    }

    public String getCardNum() {
        return cardNum;
    }

    public void setCardNum(String cardNum) {
        this.cardNum = cardNum;
    }

    public String getOperType() {
        return operType;
    }

    public void setOperType(String operType) {
        this.operType = operType;
    }

    @Override
    public String toString() {
        StringBuilder stringBuilder = new StringBuilder();
        if (cardType.equals(Constants.REQUEST_PARAM_MSISDN)) {
            stringBuilder.append("所查询的物联卡号码(MSISDN):").append(cardNum).append(",");
        } else if (cardType.equals(Constants.REQUEST_PARAM_ICCID)) {
            stringBuilder.append("集成电路卡识别码(ICCID):").append(cardNum).append(",");
        } else if (cardType.equals(Constants.REQUEST_PARAM_IMSI)) {
            stringBuilder.append("国际移动用户识别码(IMSI):").append(cardNum).append(",");
        }
        if (operType.equals("0")) {
            stringBuilder.append("操作类型:").append("申请停机(已激活转已停机)");
        } else if (operType.equals("1")) {
            stringBuilder.append("操作类型:").append("申请复机(已停机转已激活)");
        } else if (operType.equals("2")) {
            stringBuilder.append("操作类型:").append("库存转已激活");
        } else if (operType.equals("3")) {
            stringBuilder.append("操作类型:").append("可测试转库存");
        }else if (operType.equals("4")) {
            stringBuilder.append("操作类型:").append("可测试转待激活");
        }else if (operType.equals("5")) {
            stringBuilder.append("操作类型:").append("可测试转已激活");
        }else if (operType.equals("6")) {
            stringBuilder.append("操作类型:").append("待激活转已激活");
        }
        return stringBuilder.toString();
    }
}
